package com.jsong.linuo.array;

/**
 * @author 黎诺
 */
public class Array02 {
    public static void main(String[] args) {
        String[][] arr1 = {{"孙悟空", "猪八戒"}, {"刘备", "张飞", "关羽"}, {"林黛玉", "贾宝玉"}};
        System.out.println(arr1.length);

        //获取每一个一维数组的长度
        for (int i = 0; i < arr1.length; i++) {
            /*
                arr1[i]代表的是每一个一维数组
             */
            System.out.println(arr1[i].length);
        }
    }
}
